home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3 / f90 / repeat.z / repeat
Encoding:
Text File  |  2002-10-03  |  1.9 KB  |  56 lines

  1. REPEAT(3I)                                            Last changed: 4-13-99
  2.  
  3.  
  4. NNAAMMEE
  5.      RREEPPEEAATT - Concatenates several copies of a string
  6.  
  7. SSYYNNOOPPSSIISS
  8.      RREEPPEEAATT (([SSTTRRIINNGG==]_s_t_r_i_n_g,, [NNCCOOPPIIEESS==]_n_c_o_p_i_e_s))
  9.  
  10. IIMMPPLLEEMMEENNTTAATTIIOONN
  11.      UNICOS, UNICOS/mk, IRIX systems
  12.  
  13.      CF90, MIPSpro 7 Fortran 90
  14.  
  15. SSTTAANNDDAARRDDSS
  16.      Fortran
  17.  
  18. DDEESSCCRRIIPPTTIIOONN
  19.      The RREEPPEEAATT intrinsic function concatenates several copies of a string.
  20.      It returns the specified number of concatenated copies of the input
  21.      string as the result.  If the number of copies is zero, the result is
  22.      a string of zero length.
  23.  
  24.      RREEPPEEAATT accepts the following arguments:
  25.  
  26.      _s_t_r_i_n_g    Must be a scalar and of type character.
  27.  
  28.      _n_c_o_p_i_e_s   Must be either 0 or a positive integer.  Must also be a
  29.                scalar.
  30.  
  31.      RREEPPEEAATT is a transformational function.  The name of this intrinsic
  32.      cannot be passed as an argument.
  33.  
  34. RREETTUURRNN VVAALLUUEESS
  35.      The result is a scalar entity of type character with a length of
  36.      _n_c_o_p_i_e_s times the length of _s_t_r_i_n_g.  The value of the result is the
  37.      concatenation of _n_c_o_p_i_e_s of _s_t_r_i_n_g.
  38.  
  39.      If _n_c_o_p_i_e_s is zero, the result is a string of zero length.
  40.  
  41. EEXXAAMMPPLLEESS
  42.      In the following program, a literal with a trailing blank is repeated.
  43.  
  44.           CHARACTER*14 CHVAR
  45.           CHVAR = REPEAT('STRING ',2)
  46.           PRINT '(3A)', '>', CHVAR, '<'
  47.           END
  48.  
  49.      The output of the program is:
  50.  
  51.           >STRING STRING <
  52.  
  53. SSEEEE AALLSSOO
  54.      _I_n_t_r_i_n_s_i_c _P_r_o_c_e_d_u_r_e_s _R_e_f_e_r_e_n_c_e _M_a_n_u_a_l for the printed version of this
  55.      man page.
  56.